package br.com.musclebook.entity;

import java.io.Serializable;

import javax.persistence.Entity;
import javax.persistence.Lob;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.PrimaryKeyJoinColumn;
import javax.persistence.Table;

@Entity
@Table(name = "BUILD_IN_EXERCISE")
@NamedQueries({
    @NamedQuery(name = "BuildInExercise.listByCategory", query = "select buildInExer from BuildInExercise buildInExer where buildInExer.primaryCategory =:category order by upper(buildInExer.name)"),
    @NamedQuery(name = "BuildInExercise.listNames", query = "select buildInExer.name from BuildInExercise buildInExer where upper(buildInExer.name) like :name order by upper(buildInExer.name)"),
    @NamedQuery(name = "BuildInExercise.listByName", query = "select buildInExer from BuildInExercise buildInExer where upper(buildInExer.name) like :name order by upper(buildInExer.name)")
    })
@PrimaryKeyJoinColumn(name = "EXERCISE_ID")
public class BuildInExercise extends Exercise implements Serializable {

    private static final long serialVersionUID = 1L;
    
    @Lob
    private byte[] image;

    public byte[] getImage() {
        return image;
    }

    public void setImage(byte[] image) {
        this.image = image;
    }
    
    

}
